package org.darcy.youchat.activity.me.card;

import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;

import org.darcy.youchat.R;
import org.darcy.youchat.activity.BaseActivity;
import org.darcy.youchat.databinding.ActivityMsgNotificationBinding;

/**
 * me->卡包->消息通知
 */
public class MsgNotificationActivity extends BaseActivity {

    private ActivityMsgNotificationBinding binding;

    @Override
    public void initView() {
        binding = ActivityMsgNotificationBinding.inflate(getLayoutInflater());
        setContentView(binding.getRoot());
        setSupportActionBar(binding.mToolbar.toolbar);
        binding.mToolbar.toolbar.setNavigationIcon(R.mipmap.ic_back);
        getSupportActionBar().setTitle("消息通知");
    }

    @Override
    public boolean onCreateOptionsMenu(Menu menu) {
        new MenuInflater(this).inflate(R.menu.menu_one_text, menu);
        menu.getItem(0).setTitle("清空").setEnabled(false);
        return super.onCreateOptionsMenu(menu);
    }

    @Override
    public boolean onOptionsItemSelected(MenuItem item) {
        if (item.getItemId() == android.R.id.home) {
            finish();
        }
        return super.onOptionsItemSelected(item);
    }

}